package com.cc.service.impl;

import com.cc.entity.ChildrenCategory;
import com.cc.entity.ParentCategory;
import com.cc.mapper.CategoryMapper;
import com.cc.service.CategoryService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @program:
 * @ClassName:
 * @description:
 * @author: zgc
 * @date:
 * @Version 1.0
 **/
@Service
public class CategoryServiceImpl implements CategoryService {
    @Resource
    private CategoryMapper categoryMapper;

    @Override
    public List<ParentCategory> selectParentCategory(ParentCategory parentCategory) {
        return categoryMapper.selectParentCategory(parentCategory);
    }

    @Override
    public List<ChildrenCategory> selectChildrenCategory(ChildrenCategory childrenCategory) {
        return categoryMapper.selectChildrenCategory(childrenCategory);
    }

    @Override
    public int insertChildrenCategory(ChildrenCategory childrenCategory) {
        return categoryMapper.insertChildrenCategory(childrenCategory);
    }
}
